package com.cti.ftpservice.utils;

import org.apache.commons.net.ftp.FTPFile;
import org.apache.commons.net.ftp.FTPFileFilter;

public class XmlFtpFileFilter implements FTPFileFilter {

	@Override
	public boolean accept(FTPFile file) {
		if(file.isDirectory())
			return true;
		String filename = file.getName().toLowerCase();
		if(filename.contains(".xml")){
			return true;
		}else{
			return false;
		}
	}

}
